Gemini Proxy
Suggestions for a Gemini server
* 📧 Messages: 2
* 🗣️ Authors: 2
* 📅 First Message: 2021-12-20 07:36
* 📅 Last Message: 2021-12-20 08:28
1. Jason Evans (jsevans (a) mailfence.com)
* 📅 Sent: 2021-12-20 07:36
* 📧 Message 1 of 2
Hi all,
I've been running molly-brown for some time and I really like its
flexibility when it comes to handling funky mime types. I've been hosting
a gemini mirror to textfiles.com for a while and lot of these files have random
file extensions but they are actually all plain text files. With molly, I
can define mime types like this:
[MimeOverrides]
"atom.xml$" = "application/atom+xml"
"rss.xml$" = "application/rss+xml"
".$" = "text/plain"
".gmi$" = "text/gemini"
".tgz$" = "application/gzip"
".zip$" = "application/zip"
".tar.gz$" = "application/gzip"
That way anything that isn't defined is automatically assumed to be
"text/plain" which works great for me.
I tried using gmnisrv and it has some wonderful features like certificate
generation and the ability to create multiple capsules however, custom
mime types must be managed manually which means that I would probably need
to rename every file in the textfiles collection to .txt or .gmi which I
really don't want to do.
I'm looking for suggestions for a server that can give me all of these
functions together in one place. Thanks!
2. Omar Polo (op (a) omarpolo.com)
* Subject Changed! New Subject: Re: Suggestions for a Gemini server
* 📅 Sent: 2021-12-20 08:28
* 📧 Message 2 of 2
Jason Evans <jsevans@mailfence.com> writes:
`! Hi all,`!
`!`!
`! I've been running molly-brown for some time and I really like its`!
`! flexibility when it comes to handling funky mime types. I've been hosting`!
`! a gemini mirror to textfiles.com for a while and lot of these files`!
`! have random`!
`! file extensions but they are actually all plain text files. With molly, I`!
`! can define mime types like this:`!
`!`!
`! [MimeOverrides]`!
`! "atom.xml$" = "application/atom+xml"`!
`! "rss.xml$" = "application/rss+xml"`!
`! ".$" = "text/plain"`!
`! ".gmi$" = "text/gemini"`!
`! ".tgz$" = "application/gzip"`!
`! ".zip$" = "application/zip"`!
`! ".tar.gz$" = "application/gzip"`!
`!`!
`!`!
`! That way anything that isn't defined is automatically assumed to be`!
`! "text/plain" which works great for me.`!
`!`!
`! I tried using gmnisrv and it has some wonderful features like certificate`!
`! generation and the ability to create multiple capsules however, custom`!
`! mime types must be managed manually which means that I would probably need`!
`! to rename every file in the textfiles collection to .txt or .gmi which I`!
`! really don't want to do.`!
`!`!
`! I'm looking for suggestions for a server that can give me all of these`!
`! functions together in one place. Thanks!`!
shameless self-promotion :)
I've never used molly brown nor gmnisrv, but my server gmid[0] has
location blocks and settings customizable per-location block. That
means that you can either
server "example.com" {
cert "..."
key "..."
root "..."
# set the default mime to text/plain
default type "text/plain"
}
or even
server "example.com" {
cert "..."
key "..."
root "..."
location "/text-files/*" {
default type "text/plain"
}
}
to change the 'default type' only for files that matches "/text-file/*".
It's also possible to define custom mime-types per extensions using the
'map mime-type to-ext extension', see the manpage for usage and
examples.
Regarding the automatic renewal of certificates, there's nothing in the
current last version (v1.7.5) but in -master there's an helper script in
contrib/ to automatically renew the certificates (it's meant to be ran
from a crontab or similar) and I'd like to tag the 1.8 with the new
year.
[0]: gemini://gmid.omarpolo.com
or https://gmid.omarpolo.com
---
you're on gemi.dev/gemini-mailing-list/001096.gmi